<?

include_once "accesscontrol.php";


$q1 = "select fname, job_seeker_email from job_seeker_info where uname = \"$_SESSION[uname]\" ";
$r1 = mysql_query($q1) or die(mysql_error());
$a1 = mysql_fetch_array($r1);

$from = "From:$a1[0] <$a1[1]>";
$subject = "Job offer";
$message = strip_tags($fmessage);
$to = strip_tags($femail);

mail($to, $subject, $message, $from);

echo "<br><br><br><center><span class=BlackLink>The message was sent to $to<br><br><a href=\"JobInfo.php?job_id=$job_id\" class=BlackLink>Back to the job offer.</a> </span></center>";

include_once('../footer.php'); 

?>